import cv2

img = cv2.imread("../asset/cube.jpeg")
gray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)
dst = cv2.cornerHarris(gray, 4, 3, 0.04)
img[dst > 0.01 * dst.max()] = (0, 0, 255)
while True:
    cv2.imshow('img', img)
    key = cv2.waitKey(10)
    if key & 0xFF == ord('q'):
        break
cv2.destroyAllWindows()
